/* 重构 vant 组件样式 */
.mqu-toast {
  padding: 25px !important;
  min-width: 150px !important;
  background-color: #000 !important;
  font-size: 24px !important;
  line-height: 1.25 !important;
  color: #fff !important;
  border-radius: 50px !important;
  opacity: 0.6 !important;
  box-shadow: 0 3px 6px #000 !important;
}

.van-progress__portion {
  transition: all 1s cubic-bezier(0.4, 0, 0, 1) !important;
}

.mqu-dialog {
  border-radius: 10px !important;
  width: 570px !important;

  .van-dialog__content {
    padding: 70px 40px 30px;

    .van-dialog__message {
      font-size: 30px;
      line-height: 30px;
      color: #333;
    }
  }

  .van-dialog__footer {
    padding: 35px 0;
    display: flex;
    justify-content: center;
    align-items: center;

    [class*='van-hairline']::after {
      border: none;
    }

    .van-dialog__cancel,
    .van-dialog__confirm {
      padding: 15px 24px 12px;
      width: auto;
      height: auto;
      font-size: 28px;
      line-height: 28px;
      border-radius: 50px;
      background: #fff;
      background-color: #fff;
      flex: none;

      .van-button__text {
        font-size: 28px;
        line-height: 28px;
      }
    }

    /* 左边按钮 */
    .van-dialog__cancel {
      border: 2px solid #008fff;
      margin-right: 50px;

      .van-button__text {
        color: #008fff;
      }

      &:active {
        background: #008fff;
        background-color: #008fff;

        .van-button__text {
          color: #fff;
        }
      }
    }

    /* 右边按钮 */
    .van-dialog__confirm {
      border: 2.5px solid #da261c;

      .van-button__text {
        color: #da261c;
      }

      &:active {
        background: #da261c;
        background-color: #da261c;

        .van-button__text {
          color: #fff;
        }
      }
    }

    &::after {
      border-color: #fff;
    }
  }
}

.field-scrollbar() {
  /* 针对缺省样式 (必须的) */
  ::-webkit-scrollbar {
    width: 10px;
    height: 0px;
  }
  /* 滚动条的滑轨背景颜色 */
  ::-webkit-scrollbar-track {
    background-color: #fff;
    border-radius: 5px;
  }
  /* 滑块颜色 */
  ::-webkit-scrollbar-thumb {
    background-color: #dce8ff;
    border-radius: 5px;
  }
  /*内层轨道的颜色*/
  ::-webkit-scrollbar-track-piece {
    background-color: #fff;
    border-radius: 5px;
  }
  /* 滑轨两头的监听按钮颜色 */
  ::-webkit-scrollbar-button {
    background-color: #fff;
    width: 0;
    height: 0;
  }
  /* 横向滚动条和纵向滚动条相交处尖角的颜色 */
  ::-webkit-scrollbar-corner {
    background-color: #fff;
  }
}

.mqu-field {
  .field-scrollbar();

  .van-cell__value,
  .van-field__body,
  .van-field__control {
    color: inherit !important;
    opacity: inherit !important;
    font-weight: inherit !important;
    text-shadow: inherit !important;
  }

  .van-field__control {
    height: 365px !important;
    font-size: 30px !important;
    line-height: 30px !important;
  }

  &.bgc-inverse {
    background-color: #7e7e7e;

    .van-field__control::-webkit-input-placeholder {
      color: #fff;
    }
    .van-field__control::-moz-input-placeholder {
      color: #fff;
    }
    .van-field__control::-ms-input-placeholder {
      color: #fff;
    }
  }
}

.mqu-field-fill {
  height: 100% !important;

  .van-cell__value,
  .van-field__body,
  .van-field__control {
    height: 100% !important;
  }
}

.mqu-slider {
  .van-slider__button {
    width: 36px !important;
    height: 36px !important;
  }
}

.mqu-popup {
  top: unset !important;
  bottom: 0 !important;
  left: 0 !important;
  right: 0 !important;
  transform: unset !important;
}

.qu-field {
  .field-scrollbar();

  .van-cell__value,
  .van-field__body,
  .van-field__control {
    height: 100% !important;
    font-size: inherit !important;
    line-height: inherit !important;
    color: inherit !important;
    opacity: inherit !important;
    font-weight: inherit !important;
    text-shadow: inherit !important;
  }

  .van-field__control {
    padding: 8px 0 !important;
  }

  .van-field__control::-webkit-input-placeholder {
    color: #e0e0e0;
  }
  .van-field__control::-moz-input-placeholder {
    color: #e0e0e0;
  }
  .van-field__control::-ms-input-placeholder {
    color: #e0e0e0;
  }
}

.qu-uploader {
  .van-uploader__upload {
    margin: 0 22px 22px 0;
    width: 215px;
    height: 215px;
    border: none;
    background: url(../assets/img/icon_add_to_normal.png) center center no-repeat;
    background-size: 100% 100%;

    &:nth-of-type(3),
    &:nth-of-type(6),
    &:nth-of-type(9) {
      margin: 0;
    }

    &:active {
      background: url(../assets/img/icon_add_to_press.png) center center no-repeat;
      background-size: 100% 100%;
    }

    .van-icon,
    .van-icon::before {
      display: none;
    }
  }

  &.is-reading .van-uploader__upload {
    display: none;
  }

  .van-uploader__preview {
    margin: 0 22px 22px 0;

    &:nth-of-type(3),
    &:nth-of-type(6),
    &:nth-of-type(9) {
      margin: 0;
    }
  }

  .van-uploader__preview-image {
    width: 215px;
    height: 215px;
    pointer-events: none;

    .van-image__img {
      border-radius: 10px;
    }
  }

  .van-uploader__preview-delete {
    padding: 0;
    top: -15px;
    right: -15px;
    bottom: auto;
    width: 50px;
    height: 50px;
    cursor: pointer;
    background: url(../assets/img/icon_delete_normal.png) center center no-repeat;
    background-size: 100% 100%;
    background-color: transparent;

    &::before {
      content: '';
      display: none;
    }

    &:active {
      background: url(../assets/img/icon_delete_press.png) center center no-repeat;
      background-size: 100% 100%;
      background-color: transparent;
    }
  }
}

.qu-progress {
  .van-progress__portion {
    transition: none !important;
  }
}

.vote-dialog {
  .van-dialog__header {
    padding-top: 0;
    height: 75px;
    line-height: 75px;
    text-align: center;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-size: 34px;
    box-sizing: border-box;
    font-weight: normal;
  }

  .van-cell__value,
  .van-field__body,
  .van-field__control {
    color: inherit !important;
    font-size: inherit !important;
  }

  .van-field__control {
    border-radius: 0;
    border-bottom: 2px solid #333;
  }

  .van-dialog__footer {
    padding: 80px 0 24px;
    display: flex;
    justify-content: center;
    align-items: center;

    [class*='van-hairline']::after {
      border: none;
    }

    .van-dialog__cancel,
    .van-dialog__confirm {
      padding: 15px 34px 12px;
      width: auto;
      height: auto;
      font-size: 28px;
      line-height: 28px;
      border-radius: 50px;
      background: #fff;
      background-color: #fff;
      flex: none;

      .van-button__text {
        font-size: 28px;
        line-height: 28px;
      }
    }

    /* 左边按钮 */
    .van-dialog__cancel {
      border: 2px solid #008fff;
      margin-right: 50px;

      .van-button__text {
        color: #008fff;
      }

      &:active {
        border: 2px solid #0285eb;
        background: #0285eb;
        background-color: #0285eb;

        .van-button__text {
          color: #fff;
        }
      }
    }

    /* 右边按钮 */
    .van-dialog__confirm {
      border: 2px solid #008fff;
      background: #008fff;
      background-color: #008fff;

      .van-button__text {
        color: #fff;
      }

      &:active {
        border: 2px solid #0285eb;
        background: #0285eb;
        background-color: #0285eb;
      }
    }

    &::after {
      border-color: #fff;
    }
  }

  /* 禁用下的右边按钮 */
  &.disabled {
    .van-dialog__confirm,
    .van-dialog__confirm:active {
      border: 2px solid #7fc7ff;
      background: #7fc7ff;
      background-color: #7fc7ff;
      pointer-events: none;
    }
  }
}
